<?php

namespace app\core;

class classLoader
{
    public static $classMap = [];
    public static function load($class)
    {
        
        $class=str_replace('\\','/',$class);

        if (isset(self::$classMap[$class])) {
            return true;
        } else {
            $file = APP .'/'. $class . '.php';
           
            if (is_file($file)) {
                include $file;
                self::$classMap[$class] = $class;
            } else {
                return false;
            }
        }
    }
}
